package com.cjy.checkin.controller;

import com.cjy.checkin.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;

@Controller
public class ShowController {
    @Autowired
    private UserService userService;
    @GetMapping("/pushIn")
    public String pushIn(String name){

        userService.updateCheckIn(name);
        return "userList";
    }
    @GetMapping("/")
    public String pushInView(){
        return "/except";
    }

    @GetMapping("/list")
    public String list(){
         return "userList";
    }

}
